home *** CD-ROM | disk | FTP | other *** search
/ Champak Vol A-4 / (Vol A-4) Vol. A4.iso / Games / loa_and_the_island.swf / scripts / DefineSprite_870 / frame_8 / PlaceObject2_812_1 / CLIPACTIONRECORD onClipEvent(enterFrame).as next >
Text File  |  2008-03-17  |  756b  |  23 lines

  1. onClipEvent(enterFrame){
  2.    if(_root.paused == false)
  3.    {
  4.       if(_global.redkey == true and _global.bluekey == true and _global.yellowkey == true and _global.greenkey == true and _global.blackkey == true and (this.hitTest(_root.level.sprite._x + _root.level._x + 50,_root.level.sprite._y + _root.level._y - 30,true) or this.hitTest(_root.level.sprite._x + _root.level._x - 50,_root.level.sprite._y + _root.level._y - 30,true)))
  5.       {
  6.          open = true;
  7.       }
  8.       if(open == true and _currentframe < _totalframes)
  9.       {
  10.          play();
  11.       }
  12.       if(_currentframe == _totalframes)
  13.       {
  14.          this.swapDepths(0);
  15.          removeMovieClip(this);
  16.       }
  17.    }
  18.    if(_root.paused == true)
  19.    {
  20.       stop();
  21.    }
  22. }
  23.